package com.gwtgeo.ui.client.mvp.windowsmanager;

import com.gwtgeo.ui.client.gin.GwtgeoGinFactory;

public class WindowsProvider {

	public WindowsProvider() {
		super();
	}

	public WindowedPresenter<? extends WindowedDisplay> getWindow(
			WindowTypeEnum type) {
		switch (type) {
		case LAYERS:
			return GwtgeoGinFactory.injector.getLayersPresenter();
		case MAP:
			return GwtgeoGinFactory.injector.getMapPresenter();
		case SAVE_AS:
			return GwtgeoGinFactory.injector.getSaveAsPresenter();
		case SEARCH_FORM:
			return GwtgeoGinFactory.injector.getSearchFormPresenter();
		case SEARCH_RESULTS:
			return GwtgeoGinFactory.injector.getSearchResultsPresenter();
		case ADD_LAYER:
			return GwtgeoGinFactory.injector.getAddLayerPresenter();
		case LOAD:
			return GwtgeoGinFactory.injector.getLoadPresenter();
		case NEW:
			return GwtgeoGinFactory.injector.getNewMapPresenter();
		default:
			return null;
		}
	}

}
